package com.canyou.common;

import com.jfinal.core.Controller;

/**
 * CanYou自定义Controller父类
 * 
 * @created cgz 2012-12-23
 */
public class CanYouController extends Controller {
	/**
	 * 判断是否弹出toast
	 * 
	 * @author cgz 2012-12-23
	 * @return
	 */
	public Controller totast() {
		if (null != getSessionAttr("toast")) {
			String toast = getSessionAttr("toast").toString();
			setAttr("toast", toast);
			removeSessionAttr("toast");
		}
		return this;
	}
}
